package com.zbmsg.group.service;

import java.util.List;

import com.zbmsg.group.bean.Group;

public interface IGroupService {

	/**
	 * 创建房间
	 * 
	 * @return
	 * @throws Exception
	 */
	public String add(Group group) throws Exception;

	/**
	 * 清除房间(离线时候判断房间是否有人)
	 * 
	 * @throws Exception
	 */
	public void clean(String groupId) throws Exception;
	
	/**
	 * 获取group对象
	 * @param groupId
	 * @return
	 * @throws Exception
	 */
	public Group getGroup(String groupId) throws Exception;
	
	/**
	 * 是否创建建了房间
	 * @param userId
	 * @return
	 * @throws Exception
	 */
	public Group isCreateGroup(String userId) throws Exception;
	
	/**
	 * 房间列表
	 * @return
	 * @throws Exception
	 */
	public List<Group> listWithGroups() throws Exception;
}
